using System;
using System.Collections.Generic;
using System.Text;
using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Audio;
using Microsoft.Xna.Framework.Content;
using Microsoft.Xna.Framework.Graphics;
using Microsoft.Xna.Framework.Input;
using Microsoft.Xna.Framework.Storage;
using SolanumSolstice_Windows.Mapping;
using SolanumSolstice_Windows.Buildings;

namespace SolanumSolstice_Windows.Units
{
    public class Genius : Scholar
    {
        public Genius(ContentManager content, Vector2 position)
            : base(content, position)
        {
            texture = content.Load<Texture2D>("Content\\Txtr\\Units\\Sprites\\sci_genius_sheet");
            hudTexture = content.Load<Texture2D>("Content\\Txtr\\Units\\HUD\\researcherHUD");
            this.hitPoints = 15;  //compared to 12
            maxHitPoints = hitPoints;
            velocity = 2.4f;  //compared to 2.2
            sightRadius = 2;
            attackPower = 1;
            unitClass = UnitClass.Science;

            isHealing = false;
            isResearching = false;
            healPower = 4;
            researchPower = 9;  //compared to 4
            researchTime = 5;
            healingTime = 6;

            spawnCost = 32;  //compared to 16
            timeCost = 24;   //compared to 16

        }

        public override Object Clone()
        {
            Genius u = new Genius(this.content, this.position);

            u.weapon = this.weapon;
            u.hitPoints = this.hitPoints;
            u.maxHitPoints = this.maxHitPoints;
            u.recoveryTime = this.recoveryTime;
            u.initialRecoveryTime = this.initialRecoveryTime;
            u.position = this.position;
            u.velocity = this.velocity;
            u.sightRadius = this.sightRadius;
            u.attackRadius = this.attackRadius;
            u.attackPower = this.attackPower;
            u.isSelected = this.isSelected;
            u.isDead = this.isDead;
            u.isDying = this.isDying;
            u.isZombie = this.isZombie;
            u.inBuilding = this.inBuilding;
            u.isAttacking = this.isAttacking;
            u.actionSelected = this.actionSelected;
            u.actionReady = this.actionReady;
            u.rand = this.rand;
            u.actions = this.actions;
            u.currentActionIndex = this.currentActionIndex;
            u.targetReached = this.targetReached;
            u.direction = new Vector2(this.direction.X, this.direction.Y);
            u.unitClass = this.unitClass;

            u.isHealing = this.isHealing;
            u.isResearching = this.isResearching;
            u.targetBuilding = this.targetBuilding;
            u.healPower = this.healPower;
            u.healingTime = this.healingTime;
            u.researchPower = this.researchPower;
            u.researchTime = this.researchTime;

            u.timeCost = this.timeCost;
            u.spawnCost = this.spawnCost;

            return u;

        }
    }

}
